const mysql = require("mysql");
const connection = mysql.createConnection({
    host: "localhost",
    user: "root",
    password: "root",
    database: "fileupload",
});

connection.connect((err)=>{
    if(err) {
        console.error("Failed to connect to database: " + err);
        return;
    }
    console.log('Connect to database successfully!');
})

module.exports = connection;